import $store from '@/store/index.js';
import groupApi from "@/services/api/group.js"
import groupMembersSqlite from '@/sqlite_services/group_members.js'
//踢人群聊
const handle = async(data)=>{
	try{
		let myid = $store.state.user.user_info.user_id
		//如果包含我
		if(data.weedout_ids.includes(myid)){
			groupApi.outOrDissolve(data.target_id)
			// groupApi.outOrDissolve(data.target_id)
		}
		//发送全局通知,通知页面删除好友
		uni.$emit('onGroupMemberAction',{
			type:'delMember',
			data:{
				group_id:data.target_id,
				user_ids:data.weedout_ids
			}
		})
	}catch(e){
		
	}
}
export default handle